const fp = require("lodash/fp");
const cars = [
    {name:"111",horsepower:40,dollar_value:80,in_stock:true},
    {name:"112",horsepower:41,dollar_value:81,in_stock:true},
    {name:"113",horsepower:42,dollar_value:82,in_stock:false},
    {name:"114",horsepower:43,dollar_value:83,in_stock:true},
    {name:"115",horsepower:44,dollar_value:84,in_stock:false},
]

let log = function(data) {
    console.log(data);
    return data;
}

let getFirstCarName = fp.flowRight(fp.prop('name'), fp.first)


let result = getFirstCarName(cars);
console.log(result);